package com.qs.order.exception;

import com.qs.order.enums.ResultEnum;

/**
 * @Desc:  自定义表单异常
 * @author: jianfeng
 * @Time: 2019/9/17 10:37
 */
public class OrderException extends RuntimeException {

    private Integer code;

    public OrderException(Integer code,String message){
        super(message);
        this.code=code;

    }

    public OrderException(ResultEnum resultEnum){
        super(resultEnum.getMessage());
        this.code=resultEnum.getCode();
    }
}
